package com.fuyao.cloud.admin.api.feign;

import com.fuyao.cloud.admin.api.vo.UserRoleVO;
import com.fuyao.cloud.common.core.constant.ServiceNameConstants;
import com.fuyao.cloud.common.core.util.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

import java.util.List;

/**
 *
 * 角色远程调用。
 *
 * @author cloud
 * @date 2020/5/12
 * <p>
 * 查询参数相关
 */
@FeignClient(contextId = "remoteRoleService", value = ServiceNameConstants.UPMS_SERVICE)
public interface RemoteRoleService {

	/**
	 * 通过字典类型查找字典
	 * @param code 字典类型
	 * @return 同类型字典
	 */
	@GetMapping("/role/code/{code}/{roleId}")
	R<List<UserRoleVO>> listRoleByRoleCode(@PathVariable("code") String code,@PathVariable("roleId") Long roleId);

}
